#pragma once

namespace net_tools
{
  class Eventloop;
  namespace net
  {
    class Connect;
  }
}
#define USING_FAST_FUNCTION 1
#if USING_FAST_FUNCTION
#include "util/fast_function.h"

using func = Function<void(), 64>;
using connect_func = Function<void(net_tools::net::Connect *), 64>;
using eventloop_func = Function<void(net_tools::Eventloop *), 64>;
using message_func = Function<unsigned int(net_tools::net::Connect *, char *, unsigned int), 64>;
using rpc_callback = Function<void(net_tools::net::Connect *, void *, unsigned int), 64>;

#else
#include <functional>
using func = std::function<void()>;
using connect_func = std::function<void(net_tools::net::Connect *)>;
using eventloop_func = std::function<void(net_tools::Eventloop *)>;
using message_func = std::function<unsigned int(net_tools::net::Connect *, char *, unsigned int)>;
using rpc_callback = std::function<void(net_tools::net::Connect *, void *, unsigned int)>;
#endif